<table>
  <thead>
    <tr>
      <th><%= t("models.admin.fields.email", scope: "decidim.system") %></th>
      <th><%= t("models.admin.fields.created_at", scope: "decidim.system") %></th>
      <th><%= t("actions.title", scope: "decidim.system") %></th>
    </tr>
  </thead>
  <tbody>
    <% admins.each do |admin| %>
      <tr>
        <td>
          <%= link_to admin.email, edit_admin_path(admin) %><br>
        </td>
        <td>
          <%= l admin.created_at, format: :short %>
        </td>
        <td>
          <%= link_to t("actions.edit", scope: "decidim.system"), edit_admin_path(admin) %>
          <% unless current_admin?(admin) %>
            <%= link_to t("actions.destroy", scope: "decidim.system"), admin, method: :delete, data: { confirm: t("actions.confirm_destroy", scope: "decidim.system") } %>
          <% end %>
        </td>
      </tr>
    <% end %>
  </tbody>
</table>
